#include "qqwindow.h"
#include "networkcontroller.h"
#include "ui_qqwindow.h"
#include "pagecontroller.h"

QQWindow::QQWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::QQWindow)
{
    ui->setupUi(this);
    fp=new FriendPage(this);
    ui->stackedWidget->addWidget(fp);
    connect(NetWorkController::getInstance()->getCSocket(),&QTcpSocket::readyRead,NetWorkController::getInstance(),&NetWorkController::client_Recv);
}
QQWindow::~QQWindow()
{
    delete ui;
}

void QQWindow::on_pushButton_clicked()
{
    PageController::Getinstance()->showAddPage();
}

